﻿namespace ufida.u9.ait.openapi
{
	using System;
	using System.Collections.Generic;
	using System.Text;
    using ufida.u9.ait.openapi.utils;
    using UFIDA.U9.ER.LoanBill;
    using UFSoft.UBF.AopFrame;	
	using UFSoft.UBF.Util.Context;

	/// <summary>
	/// LoanBillApproveSV partial 
	/// </summary>	
	public partial class LoanBillApproveSV 
	{	
		internal BaseStrategy Select()
		{
			return new LoanBillApproveSVImpementStrategy();	
		}		
	}
	
	#region  implement strategy	
	/// <summary>
	/// Impement Implement
	/// 
	/// </summary>	
	internal partial class LoanBillApproveSVImpementStrategy : BaseStrategy
	{
		public LoanBillApproveSVImpementStrategy() { }

		public override object Do(object obj)
		{						
			LoanBillApproveSV bpObj = (LoanBillApproveSV)obj;

			return CodeUtils.DocUpdateNT<DocDTOData, LoanBill>(bpObj,
				bpObj.Data,
				(doc) =>
				{
					LoanBillBase.SubmitDoc(doc);
					LoanBillBase.ApproveDoc(doc);
					return doc;
				});
		}		
	}

	#endregion
	
	
}